package org.jsola.hr.service;

import org.jsola.core.Page;
import org.jsola.core.service.IService;
import org.jsola.hr.dao.IAttendPunchDailySummaryDAO;
import org.jsola.hr.dto.AttendPunchDailySummaryAddDTO;
import org.jsola.hr.dto.AttendPunchDailySummaryUpdateDTO;
import org.jsola.hr.entity.AttendPunchDailySummaryDO;
import org.jsola.hr.query.AttendPunchDailySummaryQuery;
import org.jsola.hr.vo.AttendPunchDailySummaryListVO;
import org.jsola.hr.vo.AttendPunchDailySummaryVO;
import org.jsola.user.core.TokenUser;

import java.util.List;


/**
 * @author zhr
 */
public interface IAttendPunchDailySummaryService extends IService<IAttendPunchDailySummaryDAO, AttendPunchDailySummaryDO> {

    /**
     * 新增考勤打卡日汇总
     * @param attendPunchDailySummaryAddDTO 新增考勤打卡日汇总DTO
     * @param tokenUser 当前用户
     * @return 考勤打卡日汇总详情信息
     */
    AttendPunchDailySummaryVO save(AttendPunchDailySummaryAddDTO attendPunchDailySummaryAddDTO, TokenUser tokenUser);

    /**
     * 修改考勤打卡日汇总
     * @param attendPunchDailySummaryUpdateDTO 修改考勤打卡日汇总DTO
     * @param tokenUser 当前用户
     * @return 更新数量
     */
    int update(AttendPunchDailySummaryUpdateDTO attendPunchDailySummaryUpdateDTO, TokenUser tokenUser);


    /**
     * 批量删除考勤打卡日汇总，物理删除，更新is_valid字段，从回收站删除
     * @param tokenUser 当前用户
     * @param attendPunchDailySummaryIds 考勤打卡日汇总id
     * @return 删除数量
     */
    int deleteByIds(TokenUser tokenUser, String...attendPunchDailySummaryIds);

    /**
     * 根据考勤打卡日汇总id查找
     * @param attendPunchDailySummaryId 考勤打卡日汇总id
     * @param siteId 所属站点id
     * @return 考勤打卡日汇总详情信息
     */
    AttendPunchDailySummaryVO selectById(String attendPunchDailySummaryId, String siteId);

    /**
     * 查询考勤打卡日汇总
     * @param attendPunchDailySummaryQuery 查询条件
     * @param siteId 所属站点id
     * @return 考勤打卡日汇总列表信息
     */
    List<AttendPunchDailySummaryListVO> select(AttendPunchDailySummaryQuery attendPunchDailySummaryQuery, String siteId);

    /**
    * 查询考勤打卡日汇总记录数
    * @param attendPunchDailySummaryQuery 查询条件
    * @param siteId 所属站点id
    * @return 考勤打卡日汇总记录数
    */
    int selectCount(AttendPunchDailySummaryQuery attendPunchDailySummaryQuery, String siteId);

    /**
     * 分页查询考勤打卡日汇总
     * @param attendPunchDailySummaryQuery 查询条件
     * @param siteId 所属站点id
     * @return 考勤打卡日汇总列表信息
     */
    Page<AttendPunchDailySummaryListVO> selectPage(AttendPunchDailySummaryQuery attendPunchDailySummaryQuery, String siteId);


    /**
     * 根据考勤打卡日汇总id查找
     * @param attendPunchDailySummaryId 考勤打卡日汇总id
     * @param siteId 所属站点id
     * @return 考勤打卡日汇总
     */
    AttendPunchDailySummaryDO selectDOById(String attendPunchDailySummaryId, String siteId);

    /**
     * 查询考勤打卡日汇总
     * @param attendPunchDailySummaryQuery 查询条件
     * @param siteId 所属站点id
     * @return 考勤打卡日汇总列表
     */
    List<AttendPunchDailySummaryDO> selectDO(AttendPunchDailySummaryQuery attendPunchDailySummaryQuery, String siteId);
}


